|
In numerical analysis, numerical differentiation describes algorithms for estimating the derivative of a mathematical function or function subroutine using values of the function and perhaps other knowledge about the function. ==Finite difference formulas== The simplest method is to use finite difference approximations. A simple two-point estimation is to compute the slope of a nearby secant line through the points (''x'',''f(x)'') and (''x+h'',''f(x+h)'').〔Richard L. Burden, J. Douglas Faires (2000), ''Numerical Analysis'', (7th Ed), Brooks/Cole. ISBN 0-534-38216-9〕 Choosing a small number ''h'', ''h'' represents a small change in ''x'', and it can be either positive or negative. The slope of this line is : This expression is Newton's difference quotient (also known as a first-order divided difference.) The slope of this secant line differs from the slope of the tangent line by an amount that is approximately proportional to ''h''. As ''h'' approaches zero, the slope of the secant line approaches the slope of the tangent line. Therefore, the true derivative of ''f'' at ''x'' is the limit of the value of the difference quotient as the secant lines get closer and closer to being a tangent line: : Since immediately substituting 0 for ''h'' results in division by zero, calculating the derivative directly can be unintuitive. Equivalently, the slope could be estimated by employing positions (x - h) and x. Another two-point formula is to compute the slope of a nearby secant line through the points (''x-h'',''f(x-h)'') and (''x+h'',''f(x+h)''). The slope of this line is : This formula is known as the symmetric difference quotient. In this case the first-order errors cancel, so the slope of these secant lines differ from the slope of the tangent line by an amount that is approximately proportional to . Hence for small values of ''h'' this is a more accurate approximation to the tangent line than the one-sided estimation. Note however that although the slope is being computed at x, the value of the function at x is not involved. The estimation error is given by: :, where is some point between and . This error does not include the rounding error due to numbers being represented and calculations being performed in limited precision. The symmetric difference quotient is employed as the method of approximating the derivative in a number of calculators, including TI-82, TI-83, TI-84, TI-85 all of which use this method with ''h''=0.001. Despite their practical popularity, finite difference formulas like the above two have been harshly criticized by some researchers, in particular by proponents of automatic differentiation. because their simplicity must be set against the fact that their accuracy is low - in rough terms, calculations in six digit precision will produce a slope of only three-digit precision whereas evaluating a function that calculates the slope may still deliver nearly six-digit precision. For example, given f(x) = x2, calculating the slope from 2x will give near full precision, whereas the finite difference approximation will have difficulties as described below. 抄文引用元・出典: フリー百科事典『 ウィキペディア(Wikipedia)』 ■ウィキペディアで「Numerical differentiation」の詳細全文を読む スポンサード リンク
|